package lgs.hm.homeWork;

import java.util.Random;

import org.springframework.stereotype.Component;

@Component
public class XiaoMing {
	
	public void visitMuseum() {
		Random r = new Random();
		int n = r.nextInt(10);
		if(n>=1 && n<4) {
			System.out.println("躲在厕所躲了一天");
			throw new RuntimeException("恐龙出来吃人");
		}
		System.out.println("小明：--看完回家之后，妈妈要求写一篇5000字的感想--");
	}

}
